# -*- coding: utf-8 -*-
# @Time     : 2021/5/8 9:59
# @Author   : pengrenjie
# @Email    : 941257162@.com
# @File     : feibo.py
class feibo():
    def __init__(self):
        self.a,self.b = 0,1
    def __iter__(self):
        return self
    def __next__(self):
        self.a,self.b = self.b,self.a + self.b
        if self.a > 1000:
            raise StopIteration
        return self.a
for i in feibo():
    print(i)
